﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Jquery選擇器.aspx.cs" Inherits="js组件_jquery_Jquery選擇器" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>Jquery : 選擇器</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    http://bbs.blueidea.com/thread-2906187-1-1.html
    
    <%
        if (false)
        {
         %>

        <script src="jquery-1.2.6-vsdoc.js" type="text/javascript"></script>
    
    <%
        }
             %>
    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.min.js"></script>
<script type="text/javascript">
/*<![CDATA[*/
//	$(function(){
//		$(":checkbox").click(function(){
//			var id = $(this).attr("id");
//			var str = id.substring(0,id.lastIndexOf("_"))+"_";
//			$(":checkbox[id^="+str+"]").each(function(){
//				var isChild = $(this).attr("id").replace(str,"");
//				if (isChild.indexOf("_")==-1) {
//					$(this).attr("checked",true);
//				}	
//			});
//		});
//	});




$(function(){

$(":checkbox").attr("checked",true);

});



    /*]]>*/



</script>
id0_1<input type="checkbox" id="id0_1" /><br />
id0_1_1<input type="checkbox" id="id0_1_1" /><br />
id0_1_1_1<input type="checkbox" id="id0_1_1_1" /><br />
id0_1_1_2<input type="checkbox" id="id0_1_1_2" /><br />
id0_1_1_3<input type="checkbox" id="id0_1_1_3" /><br />
id0_1_2<input type="checkbox" id="id0_1_2" /><br />
id0_1_2_1<input type="checkbox" id="id0_1_2_1" /><br />
id0_1_2_2<input type="checkbox" id="id0_1_2_2" /><br />
id0_1_2_3<input type="checkbox" id="id0_1_2_3" /><br />
id0_1_3<input type="checkbox" id="id0_1_3" /><br />
id0_1_3_1<input type="checkbox" id="id0_1_3_1" /><br />
id0_1_3_2<input type="checkbox" id="id0_1_3_2" /><br />
id0_1_3_3<input type="checkbox" id="id0_1_3_3" /><br />
id0_2<input type="checkbox" id="id0_2" /><br />
id0_2_1<input type="checkbox" id="id0_2_1" /><br />
id0_2_1_1<input type="checkbox" id="id0_2_1_1" /><br />
id0_2_1_2<input type="checkbox" id="id0_2_1_2" /><br />
id0_2_1_3<input type="checkbox" id="id0_2_1_3" /><br />
id0_2_2<input type="checkbox" id="id0_2_2" /><br />
id0_2_2_1<input type="checkbox" id="id0_2_2_1" /><br />
id0_2_2_2<input type="checkbox" id="id0_2_2_2" /><br />
id0_2_2_3<input type="checkbox" id="id0_2_2_3" /><br />
id0_2_3<input type="checkbox" id="id0_2_3" /><br />
id0_2_3_1<input type="checkbox" id="id0_2_3_1" /><br />
id0_2_3_2<input type="checkbox" id="id0_2_3_2" /><br />
id0_2_3_3<input type="checkbox" id="id0_2_3_3" /><br />
id0_3<input type="checkbox" id="id0_3" /><br />
id0_3_1<input type="checkbox" id="id0_3_1" /><br />
id0_3_1_1<input type="checkbox" id="id0_3_1_1" /><br />
id0_3_1_2<input type="checkbox" id="id0_3_1_2" /><br />
id0_3_1_3<input type="checkbox" id="id0_3_1_3" /><br />
id0_3_2<input type="checkbox" id="id0_3_2" /><br />
id0_3_2_1<input type="checkbox" id="id0_3_2_1" /><br />
id0_3_2_2<input type="checkbox" id="id0_3_2_2" /><br />
id0_3_2_3<input type="checkbox" id="id0_3_2_3" /><br />
id0_3_3<input type="checkbox" id="id0_3_3" /><br />
id0_3_3_1<input type="checkbox" id="id0_3_3_1" /><br />
id0_3_3_2<input type="checkbox" id="id0_3_3_2" /><br />
id0_3_3_3<input type="checkbox" id="id0_3_3_3" /><br />
    </div>
    </form>
</body>
</html>
